package com.sk.cardeal.adapter;

import android.support.annotation.Nullable;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.sk.cardeal.R;
import com.sk.cardeal.entity.OrderForm;

import java.util.List;

/**
 * Created by sk on 2018/1/20.
 */

public class OrderAdapter extends BaseQuickAdapter<OrderForm, BaseViewHolder> {

    public OrderAdapter(int layoutResId, @Nullable List<OrderForm> data) {
        super(layoutResId, data);
    }

    @Override
    protected void convert(BaseViewHolder helper, OrderForm item) {

        helper.setText(R.id.custom_name, item.getName())
                .setText(R.id.tv_phone, item.getPhone())
                .setText(R.id.car_num, item.getCardNumber())
                .setText(R.id.project_name, item.getTypeName())
                .setText(R.id.tv_time, item.getConventionTime());
    }
}
